function uplo(obj) {
	return new Promise((resolve, reject) => {
		console.log(obj.url, 'http地址')
		console.log(obj, 'obj')
		// var BASE_URL = "http://192.168.2.98:5000"
		var token = uni.getStorageSync('token');
		console.log(token, 'token')
		var BASE_URL = "https://file.xhm2006.com"
		// var BASE_URL = "http://192.168.2.98/api/BizCarousels/GetCarousel"
		// var BASE_URL = 'http://yapi.cloudmis.cn/mock/11'
		var method = obj.method || 'POST';
		var url = BASE_URL + obj.url;
		var data = obj.data;
		var headers = obj.headers || {
			ContentType: 'application/json',
			apiVersion: '1.0',
			token: token
		};
		uni.request({
			url: url,
			data: data,
			method: method,
			header: headers,
			success: (res => {
				resolve(res.data)
			}),
			fail: (err => {
				reject(err)
			})
		})
	})
}
export default uplo
